package com.hstcs.game;

import com.badlogic.ashley.core.Engine;
import com.badlogic.ashley.core.Entity;
import com.badlogic.ashley.core.EntitySystem;
import com.badlogic.gdx.Gdx;
import com.badlogic.gdx.graphics.GL20;
import com.badlogic.gdx.graphics.OrthographicCamera;
import com.badlogic.gdx.graphics.Pixmap.Format;
import com.badlogic.gdx.graphics.Texture.TextureFilter;
import com.badlogic.gdx.graphics.g2d.Animation;
import com.badlogic.gdx.graphics.g2d.Animation.PlayMode;
import com.badlogic.gdx.graphics.g2d.TextureAtlas;
import com.badlogic.gdx.graphics.g2d.TextureAtlas.AtlasRegion;
import com.badlogic.gdx.graphics.g2d.TextureRegion;
import com.badlogic.gdx.graphics.glutils.FrameBuffer;
import com.badlogic.gdx.math.MathUtils;
import com.badlogic.gdx.utils.Array;
import com.badlogic.gdx.utils.viewport.StretchViewport;
import com.hstcs.assets.Area;
import com.hstcs.assets.Assets;
import com.hstcs.assets.Config;
import com.hstcs.assets.FileName;
import com.hstcs.components.AnimationComponent;
import com.hstcs.components.BackgroundComponent;
import com.hstcs.components.BoundsComponent;
import com.hstcs.components.CameraComponent;
import com.hstcs.components.CloudComponent;
import com.hstcs.components.CreateMonsterComponent;
import com.hstcs.components.CrosshairComponent;
import com.hstcs.components.HeroComponent;
import com.hstcs.components.MonsterComponent;
import com.hstcs.components.MovementComponent;
import com.hstcs.components.StateComponent;
import com.hstcs.components.TextureComponent;
import com.hstcs.components.TimeEventComponent;
import com.hstcs.components.TransformComponent;
import com.hstcs.creator.AreaCreator;
import com.hstcs.creator.BgCreator;
import com.hstcs.creator.CameraCreator;
import com.hstcs.creator.HeroCreator;
import com.hstcs.creator.TimeEventCreator;
import com.hstcs.screen.GameScreen;
import com.hstcs.systmes.RenderingSystem;


public class God {
	
	static public God instance = null;
	
	

	public Engine engine;
	
	
	public God(Engine engine)
	{
		this.engine = engine;
		instance = this;
	}
	
	public void create()
	{
		BgCreator.create();
		AreaCreator.create(Area.maoBound);
		AreaCreator.create(Area.gouBound);
	}

	public static <T extends EntitySystem> T getSystem(Class<T> systemType) {
		return instance.engine.getSystem(systemType);
	}
}
